package com.joymeter.common.utils;

import com.alibaba.otter.canal.client.CanalConnector;
import com.alibaba.otter.canal.client.CanalConnectors;

import java.net.InetSocketAddress;

/**
 * @ClassName ConnectionUtils
 * @Description TODO
 * @Author liang
 * @Date 2018/10/12 17:39
 * @Version 1.0
 **/
public class ConnectionUtils {
    private final static String ip = "192.168.10.168";
    private final static int port = 11111;

    public static CanalConnector getConnection(){
        CanalConnector connector = CanalConnectors.newSingleConnector(new InetSocketAddress(ip, port), "example", "", "");
        return connector;
    }
}
